package com.itheima.mapper;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.itheima.pojo.CheckGroup;
import com.itheima.vo.CheckGroupVo;
import org.apache.ibatis.annotations.Select;
import org.springframework.web.bind.annotation.PathVariable;

import java.util.List;

/**
 * company: www.abc.com
 * Author: 29746
 * Create Data: 2020/11/12
 */
public interface CheckGroupMapper extends BaseMapper<CheckGroup> {

    @Select("select g.* from t_check_group g LEFT JOIN t_setmeal_group sg  on g.id=sg.group_id where  setmeal_id=#{setmealId} and delete_flag=0 ")
    List<CheckGroupVo> findCheckGroupBySetMealId(@PathVariable("setmealId") Long setmealId);
}
